import { getProjectListApi, getProjectTypeApi } from '@/service/api/businessApi';
export function projectHooks() {
  const getProjectList = async () => {
    const res = await getProjectListApi({ pageNo: 1, pageSize: 1000 });
    if (res?.data?.data) return res.data.data;
    return [];
  };

  const getProjectType = async () => {
    const res = await getProjectTypeApi();
    if (res?.data) return res.data;
    return [];
  };

  return {
    getProjectList,
    getProjectType
  };
}
